3.2380 \(\int \frac {(5-x) (3+2 x)^2}{2+5 x+3 x^2} \, dx\)

Optimal. Leaf size=29 \[ -\frac {2 x^2}{3}+\frac {44 x}{9}-6 \log (x+1)+\frac {425}{27} \log (3 x+2) \]

[Out]

44/9*x-2/3*x^2-6*ln(1+x)+425/27*ln(2+3*x)

________________________________________________________________________________________

Rubi [A]  time = 0.02, antiderivative size = 29, normalized size of antiderivative = 1.00, number of steps used = 5, number of rules used = 3, integrand size = 25, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.120, Rules used = {800, 632, 31} \[ -\frac {2 x^2}{3}+\frac {44 x}{9}-6 \log (x+1)+\frac {425}{27} \log (3 x+2) \]

Antiderivative was successfully verified.

[In]

Int[((5 - x)*(3 + 2*x)^2)/(2 + 5*x + 3*x^2),x]

[Out]

(44*x)/9 - (2*x^2)/3 - 6*Log[1 + x] + (425*Log[2 + 3*x])/27

Rule 31

Int[((a_) + (b_.)*(x_))^(-1), x_Symbol] :> Simp[Log[RemoveContent[a + b*x, x]]/b, x] /; FreeQ[{a, b}, x]

Rule 632

Int[((d_.) + (e_.)*(x_))/((a_) + (b_.)*(x_) + (c_.)*(x_)^2), x_Symbol] :> With[{q = Rt[b^2 - 4*a*c, 2]}, Dist[
(c*d - e*(b/2 - q/2))/q, Int[1/(b/2 - q/2 + c*x), x], x] - Dist[(c*d - e*(b/2 + q/2))/q, Int[1/(b/2 + q/2 + c*
x), x], x]] /; FreeQ[{a, b, c, d, e}, x] && NeQ[2*c*d - b*e, 0] && NeQ[b^2 - 4*a*c, 0] && NiceSqrtQ[b^2 - 4*a*
c]

Rule 800

Int[(((d_.) + (e_.)*(x_))^(m_)*((f_.) + (g_.)*(x_)))/((a_.) + (b_.)*(x_) + (c_.)*(x_)^2), x_Symbol] :> Int[Exp
andIntegrand[((d + e*x)^m*(f + g*x))/(a + b*x + c*x^2), x], x] /; FreeQ[{a, b, c, d, e, f, g}, x] && NeQ[b^2 -
 4*a*c, 0] && NeQ[c*d^2 - b*d*e + a*e^2, 0] && IntegerQ[m]

Rubi steps

\begin {align*} \int \frac {(5-x) (3+2 x)^2}{2+5 x+3 x^2} \, dx &=\int \left (\frac {44}{9}-\frac {4 x}{3}+\frac {317+263 x}{9 \left (2+5 x+3 x^2\right )}\right ) \, dx\\ &=\frac {44 x}{9}-\frac {2 x^2}{3}+\frac {1}{9} \int \frac {317+263 x}{2+5 x+3 x^2} \, dx\\ &=\frac {44 x}{9}-\frac {2 x^2}{3}-18 \int \frac {1}{3+3 x} \, dx+\frac {425}{9} \int \frac {1}{2+3 x} \, dx\\ &=\frac {44 x}{9}-\frac {2 x^2}{3}-6 \log (1+x)+\frac {425}{27} \log (2+3 x)\\ \end {align*}

________________________________________________________________________________________

Mathematica [A]  time = 0.01, size = 34, normalized size = 1.17 \[ -\frac {2 x^2}{3}+\frac {44 x}{9}+\frac {425}{27} \log (-6 x-4)-6 \log (-2 (x+1))+\frac {53}{6} \]

Antiderivative was successfully verified.

[In]

Integrate[((5 - x)*(3 + 2*x)^2)/(2 + 5*x + 3*x^2),x]

[Out]

53/6 + (44*x)/9 - (2*x^2)/3 + (425*Log[-4 - 6*x])/27 - 6*Log[-2*(1 + x)]

________________________________________________________________________________________

fricas [A]  time = 0.71, size = 23, normalized size = 0.79 \[ -\frac {2}{3} \, x^{2} + \frac {44}{9} \, x + \frac {425}{27} \, \log \left (3 \, x + 2\right ) - 6 \, \log \left (x + 1\right ) \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((5-x)*(3+2*x)^2/(3*x^2+5*x+2),x, algorithm="fricas")

[Out]

-2/3*x^2 + 44/9*x + 425/27*log(3*x + 2) - 6*log(x + 1)

________________________________________________________________________________________

giac [A]  time = 0.17, size = 25, normalized size = 0.86 \[ -\frac {2}{3} \, x^{2} + \frac {44}{9} \, x + \frac {425}{27} \, \log \left ({\left | 3 \, x + 2 \right |}\right ) - 6 \, \log \left ({\left | x + 1 \right |}\right ) \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((5-x)*(3+2*x)^2/(3*x^2+5*x+2),x, algorithm="giac")

[Out]

-2/3*x^2 + 44/9*x + 425/27*log(abs(3*x + 2)) - 6*log(abs(x + 1))

________________________________________________________________________________________

maple [A]  time = 0.06, size = 24, normalized size = 0.83 \[ -\frac {2 x^{2}}{3}+\frac {44 x}{9}+\frac {425 \ln \left (3 x +2\right )}{27}-6 \ln \left (x +1\right ) \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((5-x)*(2*x+3)^2/(3*x^2+5*x+2),x)

[Out]

44/9*x-2/3*x^2-6*ln(x+1)+425/27*ln(3*x+2)

________________________________________________________________________________________

maxima [A]  time = 0.56, size = 23, normalized size = 0.79 \[ -\frac {2}{3} \, x^{2} + \frac {44}{9} \, x + \frac {425}{27} \, \log \left (3 \, x + 2\right ) - 6 \, \log \left (x + 1\right ) \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((5-x)*(3+2*x)^2/(3*x^2+5*x+2),x, algorithm="maxima")

[Out]

-2/3*x^2 + 44/9*x + 425/27*log(3*x + 2) - 6*log(x + 1)

________________________________________________________________________________________

mupad [B]  time = 0.03, size = 21, normalized size = 0.72 \[ \frac {44\,x}{9}-6\,\ln \left (x+1\right )+\frac {425\,\ln \left (x+\frac {2}{3}\right )}{27}-\frac {2\,x^2}{3} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(-((2*x + 3)^2*(x - 5))/(5*x + 3*x^2 + 2),x)

[Out]

(44*x)/9 - 6*log(x + 1) + (425*log(x + 2/3))/27 - (2*x^2)/3

________________________________________________________________________________________

sympy [A]  time = 0.12, size = 27, normalized size = 0.93 \[ - \frac {2 x^{2}}{3} + \frac {44 x}{9} + \frac {425 \log {\left (x + \frac {2}{3} \right )}}{27} - 6 \log {\left (x + 1 \right )} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((5-x)*(3+2*x)**2/(3*x**2+5*x+2),x)

[Out]

-2*x**2/3 + 44*x/9 + 425*log(x + 2/3)/27 - 6*log(x + 1)

________________________________________________________________________________________